package com.example.demo.common;

import lombok.Data;

/**
 * 响应类
 * @author KUBUB
 */
@Data
public class BaseResponse<T> {
    /**
     * 状态码
     */
    private String code;
    /**
     * 接口信息
     */
    private String message;
    /**
     * 接口数据
     */
    private T data;

    public BaseResponse() {
    }

    public BaseResponse(T data) {
        this.data = data;
    }

    public BaseResponse(String code, String message) {
        this.code = code;
        this.message = message;
    }

    public BaseResponse(String code, String message, T data) {
        this.code = code;
        this.message = message;
        this.data = data;
    }

}
